package com.ruoyi.web.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.web.mapper.UserCommunityLevelMapper;
import com.ruoyi.web.domain.UserCommunityLevel;
import com.ruoyi.web.service.IUserCommunityLevelService;

/**
 * 社区成员Service业务层处理
 *
 * @author jiwei
 * @date 2024-05-17
 */
@Service
public class UserCommunityLevelServiceImpl extends ServiceImpl<UserCommunityLevelMapper, UserCommunityLevel> implements IUserCommunityLevelService {
    @Autowired
    private UserCommunityLevelMapper userCommunityLevelMapper;

    /**
     * 查询社区成员
     *
     * @param id 社区成员主键
     * @return 社区成员
     */
    @Override
    public UserCommunityLevel selectUserCommunityLevelById(Long id) {
        return userCommunityLevelMapper.selectUserCommunityLevelById(id);
    }

    /**
     * 查询社区成员列表
     *
     * @param userCommunityLevel 社区成员
     * @return 社区成员
     */
    @Override
    public List<UserCommunityLevel> selectUserCommunityLevelList(UserCommunityLevel userCommunityLevel) {
        return userCommunityLevelMapper.selectUserCommunityLevelList(userCommunityLevel);
    }

    /**
     * 新增社区成员
     *
     * @param userCommunityLevel 社区成员
     * @return 结果
     */
    @Override
    public int insertUserCommunityLevel(UserCommunityLevel userCommunityLevel) {
            return userCommunityLevelMapper.insertUserCommunityLevel(userCommunityLevel);
    }

    /**
     * 修改社区成员
     *
     * @param userCommunityLevel 社区成员
     * @return 结果
     */
    @Override
    public int updateUserCommunityLevel(UserCommunityLevel userCommunityLevel) {
        return userCommunityLevelMapper.updateUserCommunityLevel(userCommunityLevel);
    }

    /**
     * 批量删除社区成员
     *
     * @param ids 需要删除的社区成员主键
     * @return 结果
     */
    @Override
    public int deleteUserCommunityLevelByIds(Long[] ids) {
        return userCommunityLevelMapper.deleteUserCommunityLevelByIds(ids);
    }

    /**
     * 删除社区成员信息
     *
     * @param id 社区成员主键
     * @return 结果
     */
    @Override
    public int deleteUserCommunityLevelById(Long id) {
        return userCommunityLevelMapper.deleteUserCommunityLevelById(id);
    }
}
